package com.dream.service.recommender.base.entity;

import java.util.concurrent.Callable;

/**
 *  Created by zhiji on 2016/04/25.
 *  约定：所有继承 DataGetter的程序必须返回ThreadResult对象
 */
public class DataGetter implements Callable<ThreadResult>{
    protected RequestParam requestParam;
    protected boolean enableHeartbeat;
    protected boolean enableTp = true;

    public RequestParam getRequestParam() {
        return requestParam;
    }

    public void setRequestParam(RequestParam requestParam) {
        this.requestParam = requestParam;
    }

    public boolean isEnableHeartbeat() {
        return enableHeartbeat;
    }

    public void setEnableHeartbeat(boolean enableHeartbeat) {
        this.enableHeartbeat = enableHeartbeat;
    }

    public boolean isEnableTp() {
        return enableTp;
    }

    public void setEnableTp(boolean enableTp) {
        this.enableTp = enableTp;
    }

    @Override
    public ThreadResult call() throws Exception {
        throw new UnsupportedOperationException("不支持的操作");
    }

}
